package com.simple.chiralium.upms.biz.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.simple.chiralium.upms.api.entity.SysRole;
import com.simple.chiralium.upms.api.entity.SysUserRole;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 系统用户角色映射器
 * 针对表【sys_user_role(用户角色表)】的数据库操作Mapper
 *
 * @author SimpleZzz
 * @Entity com.simple.chiralium.upms.biz.entity.SysUserRole
 * @date 2021/12/09 00:55:32
 */
@Mapper
public interface SysUserRoleMapper extends BaseMapper<SysUserRole> {

    /**
     * 根据用户id查询该用户所有角色集合
     *
     * @param pkId pk id
     * @return {@link List}<{@link SysRole}>
     */
    List<SysRole> listRolesByUserId(@Param("pkId") Long pkId);
}




